#include "SpinFlyWheels.h"
#include "../Robotmap.h"
#include "WPILib.h"

SpinFlyWheels::SpinFlyWheels() {
	// Use requires() here to declare subsystem dependencies
	Requires(flyWheels);
	SetTimeout(RobotMap::SPINNING_FLYWHEEL_TIMEOUT);
}

// Called just before this Command runs the first time
void SpinFlyWheels::Initialize() {
}

// Called repeatedly when this Command is scheduled to run
void SpinFlyWheels::Execute() {
	flyWheels->setFlyWheelSpeed(oi->getLowerFlyWheelSpeed(), oi->getUpperFlyWheelSpeed());
	oi->setShootingStatus(true);
}

// Make this return true when this Command no longer needs to run execute()
bool SpinFlyWheels::IsFinished() {
	return IsTimedOut();
}

// Called once after isFinished returns true
void SpinFlyWheels::End() {
	
}

// Called when another command which requires one or more of the same
// subsystems is scheduled to run
void SpinFlyWheels::Interrupted() {
}
